package com.weixiao.repository;

import com.weixiao.model.hosp.Hospital;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * author 韩诚
 * date 2022/9/20 10:58
 */
@Repository
public interface HospitalRepository extends MongoRepository<Hospital, String> {
    /**
     * 根据医院编号获取医院信息
     * @param hoscode
     * @return
     */
    Hospital getHospitalByHoscode(String hoscode);

    /**
     * 根据医院名称获取医院列表(模糊查询)
     * @param hosname
     * @return
     */
    List<Hospital> findHospitalByHosnameLike(String hosname);
}
